package com.seawaterbt.springbootshiro.service.impl;

import com.baomidou.mybatisplus.annotations.DataSource;
import com.baomidou.mybatisplus.mapper.Wrapper;
import com.baomidou.mybatisplus.service.impl.ServiceImpl;
import com.seawaterbt.springbootshiro.annotation.SelectDataSource;
import com.seawaterbt.springbootshiro.entity.Student;
import com.seawaterbt.springbootshiro.enums.DataSourceEnum;
import com.seawaterbt.springbootshiro.mapper.StudentMapper;
import com.seawaterbt.springbootshiro.service.StudentService;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class StudentServiceImpl extends ServiceImpl<StudentMapper,Student> implements StudentService {

    @Override
    @SelectDataSource(DataSourceEnum.OTHER)
    public List<Student> selectList(Wrapper<Student> wrapper) {
        return super.selectList(wrapper);
    }
}
